<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.3.1"/>
<title>EnTech FPK: C:/Users/Sam/Projects/FRC/Libraries/Fpk/Entech-Fpk-Subscribers/Entech-Fpk/Actuators/CanJaguarWrapper.hpp Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">EnTech FPK
   &#160;<span id="projectnumber">1</span>
   </div>
   <div id="projectbrief">FRC Programming Kit by the EnTech 281 GreenVillains</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.3.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Enumerator</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_c29fdd72b58e0fec779998d59b4fd826.html">Actuators</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">CanJaguarWrapper.hpp</div>  </div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="comment">// Have include guard.</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="preprocessor">#ifndef CANJAGUARWRAPPER_HPP</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define CANJAGUARWRAPPER_HPP</span></div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="preprocessor">#include &lt;boost/smart_ptr/shared_ptr.hpp&gt;</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="preprocessor">#include &quot;WPILib.h&quot;</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="preprocessor">#include &quot;PidMotorController.hpp&quot;</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;</div>
<div class="line"><a name="l00012"></a><span class="lineno"><a class="code" href="class_can_jaguar_wrapper.html">   12</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_can_jaguar_wrapper.html">CanJaguarWrapper</a> :</div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;        <span class="keyword">public</span> <a class="code" href="class_pid_motor_controller.html">PidMotorController</a></div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;{</div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;        <span class="keyword">public</span>:</div>
<div class="line"><a name="l00019"></a><span class="lineno"><a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50f">   19</a></span>&#160;                <span class="keyword">enum</span> <a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50f">EncoderKind</a></div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;                {</div>
<div class="line"><a name="l00022"></a><span class="lineno"><a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50fa1e6b9ef545a47213e5d160c3a45e7a5d">   22</a></span>&#160;                        <a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50fa1e6b9ef545a47213e5d160c3a45e7a5d" title="The Nothing encoder kind specifies that no encoder is used.">Nothing</a>,</div>
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;                        </div>
<div class="line"><a name="l00025"></a><span class="lineno"><a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50fa385edf6e9b4cb3943783517365252ea9">   25</a></span>&#160;                        <a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50fa385edf6e9b4cb3943783517365252ea9" title="The Encoder encoder kind specifies that a normal encoder is used.">Encoder</a>,</div>
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;                        </div>
<div class="line"><a name="l00028"></a><span class="lineno"><a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50fa84351dcdff7e1476cd193258fc6efe83">   28</a></span>&#160;                        <a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50fa84351dcdff7e1476cd193258fc6efe83" title="The InvertedEncoder encoder kind specifies that an inverted encoder is used.">InvertedEncoder</a>,</div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;                        </div>
<div class="line"><a name="l00031"></a><span class="lineno"><a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50fa3af308255ef4ff5be237c5bcfd97dcd4">   31</a></span>&#160;                        <a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50fa3af308255ef4ff5be237c5bcfd97dcd4" title="The QuadEncoder encoder kind specifies that a quadrature encoder is used.">QuadEncoder</a>,</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;                        </div>
<div class="line"><a name="l00034"></a><span class="lineno"><a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50fa46263da1b0b36a80647984f7f90f1f36">   34</a></span>&#160;                        <a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50fa46263da1b0b36a80647984f7f90f1f36" title="The Potentiometer encoder kind specifies that a potentiometer is used.">Potentiometer</a></div>
<div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160;                };</div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;                </div>
<div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;                <a class="code" href="class_can_jaguar_wrapper.html#aa5d73300a96bfaae537823055038f19f">CanJaguarWrapper</a>(CANJaguar *canJaguar, <a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50f">EncoderKind</a> encoderKind, <span class="keywordtype">bool</span> canDeleteCanJaguar = <span class="keyword">false</span>);</div>
<div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;                <a class="code" href="class_can_jaguar_wrapper.html#aa5d73300a96bfaae537823055038f19f">CanJaguarWrapper</a>(CANJaguar &amp;canJaguar, <a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50f">EncoderKind</a> encoderKind);</div>
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;                <a class="code" href="class_can_jaguar_wrapper.html#aa5d73300a96bfaae537823055038f19f">CanJaguarWrapper</a>(boost::shared_ptr&lt;CANJaguar&gt; &amp;canJaguar, <a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50f">EncoderKind</a> encoderKind);</div>
<div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;                <a class="code" href="class_can_jaguar_wrapper.html#aa5d73300a96bfaae537823055038f19f">CanJaguarWrapper</a>(CANJaguar *canJaguar, <span class="keywordtype">bool</span> canDeleteCanJaguar = <span class="keyword">false</span>);</div>
<div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;                <a class="code" href="class_can_jaguar_wrapper.html#aa5d73300a96bfaae537823055038f19f">CanJaguarWrapper</a>(CANJaguar &amp;canJaguar);</div>
<div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;                <a class="code" href="class_can_jaguar_wrapper.html#aa5d73300a96bfaae537823055038f19f">CanJaguarWrapper</a>(boost::shared_ptr&lt;CANJaguar&gt; &amp;canJaguar);</div>
<div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;                </div>
<div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;                <span class="comment">/* The three following function declarations are derived from </span></div>
<div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;<span class="comment">                 * WPILib, which is licenced under the licence specified</span></div>
<div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;<span class="comment">                 * in &quot;Licence-WPILib.txt&quot;.</span></div>
<div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160;<span class="comment">                 */</span></div>
<div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_can_jaguar_wrapper.html#a7e36e59bf836b5207ae0f30728c3bd74">Set</a>(<span class="keywordtype">float</span> speed, UINT8 syncGroup = 0);</div>
<div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">float</span> <a class="code" href="class_can_jaguar_wrapper.html#a8b3379ba9b0b4fce6f866a5c3c0454c7">Get</a>();</div>
<div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_can_jaguar_wrapper.html#a310ddde37a6ee6a62e1edfe0db0ba57a">Disable</a>();</div>
<div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;                </div>
<div class="line"><a name="l00052"></a><span class="lineno">   52</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">double</span> <a class="code" href="class_can_jaguar_wrapper.html#a6418ff3efc800bf842d019695c6240df">GetSpeed</a>();</div>
<div class="line"><a name="l00053"></a><span class="lineno">   53</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">double</span> <a class="code" href="class_can_jaguar_wrapper.html#a22010432547e75a3124999ea1c107b90">GetPosition</a>();</div>
<div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_can_jaguar_wrapper.html#a0f2e3e10ff8d453d4f04af5b211c65b9">Enable</a>(<span class="keywordtype">double</span> initialEncoderPosition = 0);</div>
<div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;                <span class="keyword">virtual</span> <a class="code" href="class_pid_motor_controller.html#a13eddfb79a251f572067f2e2f214b000">ControlMode</a> <a class="code" href="class_can_jaguar_wrapper.html#af4f940e61e60e6c1ff48f2da8b5f1a00">GetControlMode</a>();</div>
<div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_can_jaguar_wrapper.html#a4d7809eaa109032e3624b4ef49979bc1">SetControlMode</a>(<a class="code" href="class_pid_motor_controller.html#a13eddfb79a251f572067f2e2f214b000">ControlMode</a> mode);</div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_can_jaguar_wrapper.html#adae396e477fce5694e7da7a15fbf0e20">SetEncodersCodesPerRevolution</a>(UINT16 codesPerRevolution);</div>
<div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_can_jaguar_wrapper.html#abc09236c254e21d02f80cfa8af906e0c">SetPid</a>(<span class="keywordtype">double</span> p, <span class="keywordtype">double</span> i, <span class="keywordtype">double</span> d);</div>
<div class="line"><a name="l00059"></a><span class="lineno">   59</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">double</span> <a class="code" href="class_can_jaguar_wrapper.html#a31397381c60457cdc00e0aeb2c8f7653">GetP</a>();</div>
<div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">double</span> <a class="code" href="class_can_jaguar_wrapper.html#a8bf0dcc40ee678cf705e3faf184e551d">GetI</a>();</div>
<div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;                <span class="keyword">virtual</span> <span class="keywordtype">double</span> <a class="code" href="class_can_jaguar_wrapper.html#a4984782f989353ced395f194ef6b19e7">GetD</a>();</div>
<div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;        <span class="keyword">private</span>:</div>
<div class="line"><a name="l00063"></a><span class="lineno">   63</span>&#160;                boost::shared_ptr&lt;CANJaguar&gt; m_canJaguar;</div>
<div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;                </div>
<div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160;                <span class="keywordtype">void</span> SetSpeedReference(CANJaguar::SpeedReference speedReference);</div>
<div class="line"><a name="l00066"></a><span class="lineno">   66</span>&#160;                <span class="keywordtype">void</span> SetPositionReference(CANJaguar::PositionReference positionReference);</div>
<div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;                <span class="keywordtype">void</span> SetupReference(<a class="code" href="class_can_jaguar_wrapper.html#a1332f9e2dc73f5fba3e9665c13abe50f">EncoderKind</a> encoderKind);</div>
<div class="line"><a name="l00068"></a><span class="lineno">   68</span>&#160;};</div>
<div class="line"><a name="l00069"></a><span class="lineno">   69</span>&#160;</div>
<div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160;<span class="preprocessor">#endif // #ifndef CANJAGUARWRAPPER_HPP</span></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Mon Aug 12 2013 16:46:48 for EnTech FPK by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.3.1
</small></address>
</body>
</html>
